import { createStore, applyMiddleware } from "redux";
import thunk from 'redux-thunk';
// import { composeWithDevTools } from 'redux-devtools-extension';
import rootReducer from '../reducers';
// 日志收集中间件
import { createLogger } from 'redux-logger';
const logger = createLogger();

// 创建store
let store = createStore(
  rootReducer,
  applyMiddleware(thunk, logger)
);

// console.log("initial state: ", store.getState());

export default store;
